import { post } from "../http";
import type { Me } from "../me/me.types";
import type { LoginFn, LoginSendVcodeFn } from "./login.types";

export const loginSendVcode: LoginSendVcodeFn = async (input) =>
  post<string>({ url: "/apis/login/send-vcode", json: input });

export const login: LoginFn = async (input) => post<Me>({ url: "/apis/login", json: input });
